package com.ruicar.afs.cloud.account.common.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.ruicar.afs.cloud.bizcommon.enums.rules.RuleTreeExpressType;
import lombok.Data;

/**
 * @author infinity
 * @version 1.0
 * @date 2020/7/1 16:58
 */
@Data
@TableName("voucher_rule_express")
public class VoucherRuleExpress {
    @JsonSerialize(using = ToStringSerializer.class)
    @TableId(type = IdType.INPUT)
    private Long id ;
    /** 规则ID */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long ruleId ;
    /** 规则itemId */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long itemId ;
    /** 表达式左类型 */
    private RuleTreeExpressType leftType ;
    /** 表达式左关联ID */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long leftReferenceId ;
    /** 表达式操作符信息 */
    private String operatorInfo ;
    /** 表达式右类型 */
    private RuleTreeExpressType rightType ;
    /** 表达式右关联ID */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long rightReferenceId ;
    /** 表达式右值 */
    private String rightValue ;
    /** 表达式右值解释（选择框用） */
    private String rightValueNames ;
}
